Now, let us take a look at some simple two-dimensional network structures: the grid, an open topology that might be useful in application areas ranging from image processing to air flow analysis for wing profile design, and its closed counterpart the torus (see figure 2).
Their specification in Parallaxis is straightforward, as shown in figure 3. It takes just four transfer-functions to specify the whole grid with each PE owning four data-ports (here called: north, south, east, and west). The torus specification is almost identical; the additional modulo- operator connects opposite boundary-PEs. When considering the grid specification, there are PEs whose neighbor function evaluates to an invalid PE-number: e.g. the PE at position [2,4] would have a right neighbor [2,5], but this is out of bounds as of the grid size fixed in the CONNECTION specification (rows labeled 0 to 3, and columns labeled 0 to 4). By definition, these PEs (called ''boundary-PEs'') simply do not have a connection in that particular direction. Any data exchange to or from the outside will have no effect (see section 4 for more detail).